﻿@using Kovan.Library.Extensions;
@using Kovan.Model.Parameter.Config;
@using Kovan.Model.Entity.Config;
@{
    ViewBag.Title = "相册管理";
    var Items = Model as List<tb_picgroup>;
    var param = ViewBag.Param as PPicGroup;
}
<style type="text/css">
    .photo_box
    {
        width: 18%;
        background-color: #F7F7F7;
        height: 200px;
        float: left;
        margin: 5px 10px;
        padding-top: 10px;
        text-align: center;
        border: 2px solid #fff;
    }
    .photo_box:hover
    {
        border: 2px solid #7CC5E5;
    }
</style>
<form id="pagerForm" method="post" action="@Url.Content("~/Manage/PicGroup")">
<input type="hidden" name="PageIndex" value="@param.PageIndex" />
<input type="hidden" name="PageSize" value="@param.PageSize" />
<input type="hidden" name="name" value="@param.name" />
</form>
<div class="pageHeader">
    <form onsubmit="return navTabSearch(this);" action="@Url.Content("~/Manage/PicGroup")" method="post">
    <div class="searchBar">
        <table class="searchContent">
            <tr>
                <td>
                    相册名称：<input type="text" name="name" value="@param.name" />
                </td>
            </tr>
        </table>
        <div class="subBar">
            <ul>
                <li>
                    <div class="buttonActive">
                        <div class="buttonContent">
                            <button type="submit">
                                检索</button></div>
                    </div>
                </li>
            </ul>
        </div>
    </div>
    </form>
</div>
<div class="pageContent">
    <div class="panelBar">
        <ul class="toolBar">
            <li><a class="add" href="@Url.Content("~/Manage/PicGroup/GetOperate")" target="dialog" rel="picgroup_operate" mask="true"  width="820" height="320" title="添加相册">
                <span>添加</span></a></li>
            <li><a class="delete" href="javascript:;" onclick="PicGroupManage.Delete();"><span>删除相册</span></a></li>
            <li class="line">line</li>
        </ul>
    </div>
    <div layouth="116">
        @if (Items != null && Items.Count > 0)
        {
            foreach (var item in Items)
            {
            <div class="photo_box">
                <a title="@item.name" href="@(Url.Content("~/Manage/PicGroup/Picture?picgroupId=") + item.picgroup_id)" rel="picgroup_upload" target="dialog" width="800" height="480" max="true">
                    <p style="width: 90%; height: 80%; margin: 0 auto;">
                        <img width="100%" height="100%" src="@Url.Content("~/content/images/folder.gif")" />
                    </p>
                </a>
                <p style="width: 90%; height: 9%; margin: 0 auto;">
                    <span style="line-height: 30px;">
                        <input type="checkbox" name="picgids" value="@item.picgroup_id" />&nbsp;@item.name</span>
                </p>
                <p style="width: 90%; height: 9%; text-align: right; margin: 0 auto;">
                    @*<input type="checkbox" /><a class="">编辑</a>*@</p>
            </div>
            }
        }
    </div>
    <div class="panelBar">
        <div class="pages">
            <span>显示</span>
            <select class="combox" name="PageSize" onchange="navTabPageBreak({numPerPage:this.value})">
                <option value="10" @(param.PageSize == 10 ? "selected=selected" : "")>10</option>
                <option value="20" @(param.PageSize == 20 ? "selected=selected" : "")>20</option>
                <option value="50" @(param.PageSize == 50 ? "selected=selected" : "")>50</option>
                <option value="100" @(param.PageSize == 100 ? "selected=selected" : "")>100</option>
                <option value="200" @(param.PageSize == 200 ? "selected=selected" : "")>200</option>
            </select>
            <span>条，共 @param.TotalRows 条</span>
        </div>
        <div class="pagination" targettype="navTab" totalcount="@param.TotalRows" numPerPage="@param.PageSize" pagenumshown="10"
            currentpage="@param.PageIndex">
        </div>
    </div>
</div>
<script type="text/javascript" src="@Url.Content2("~/Scripts/Manage/PicGroup/Index.js")"></script>
<script type="text/javascript" src="@Url.Content("~/Scripts/Highslide/highslide-with-gallery.js")"></script>
<link rel="stylesheet" type="text/css" href="@Url.Content("~/Scripts/Highslide/highslide.css")" />
